package com.zhida.courseservice.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;
import lombok.Getter;
import lombok.Setter;

/**
 * <p>
 * 
 * </p>
 *
 * @author ling
 * @since 2024-07-19
 */
@Getter
@Setter
@TableName("course")
public class Course implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 编号
     */
    @TableId(value = "course_id", type = IdType.AUTO)
    private Integer courseId;

    /**
     * 课程标题
     */
    @TableField("course_title")
    private String courseTitle;

    /**
     * 拥有者
     */
    @TableField("course_owner")
    private String courseOwner;

    /**
     * 封面 base64
     */
    @TableField("course_cover")
    private String courseCover;

    /**
     * 描述
     */
    @TableField("des")
    private String des;

    /**
     * 创建时间
     */
    @TableField("create_time")
    private LocalDateTime createTime;

    /**
     * 更新时间
     */
    @TableField("update_time")
    private LocalDateTime updateTime;

    /**
     * 0：下架，1：正常，-1：删除
     */
    @TableField("active")
    private String active;

    /**
     * 分类
     */
    @TableField("type")
    private String type;

    /**
     * 0：免费课程，1：vip
     */
    @TableField("vip")
    private Integer vip;

    /**
     * 财商
     */
    @TableField("financial")
    private Integer financial;

    /**
     * 情商
     */
    @TableField("emotional")
    private Integer emotional;

    /**
     * 技能
     */
    @TableField("skill")
    private Integer skill;

    /**
     * 资源路径
     */
    @TableField("resources")
    private String resources;

    /**
     * 得分
     */
    @TableField("score")
    private Double score;

    /**
     * 收藏
     */
    @TableField("collections")
    private Integer collections;

    /**
     * 点赞
     */
    @TableField("likes")
    private Integer likes;

    /**
     * 学员数量
     */
    @TableField("student_count")
    private Integer studentCount;

    /**
     * 课程数量
     */
    @TableField("courses")
    private Integer courses;

    /**
     * 价格
     */
    @TableField("price")
    private Double price;

    @Override
    public String toString() {
        return "Course{" +
                "courseId=" + courseId +
                ", courseTitle='" + courseTitle + '\'' +
                ", courseOwner='" + courseOwner + '\'' +
                ", courseCover='" + courseCover + '\'' +
                ", des='" + des + '\'' +
                ", createTime=" + createTime +
                ", updateTime=" + updateTime +
                ", active='" + active + '\'' +
                ", type='" + type + '\'' +
                ", vip=" + vip +
                ", financial='" + financial + '\'' +
                ", emotional='" + emotional + '\'' +
                ", skill='" + skill + '\'' +
                ", resources='" + resources + '\'' +
                ", score=" + score +
                ", collections=" + collections +
                ", likes=" + likes +
                ", studentCount=" + studentCount +
                ", courses=" + courses +
                ", price=" + price +
                '}';
    }
}
